package com.wsoft.dc.query.config;

import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * @Author z001
 * @Date 2024/12/18 09:01
 */
@Data
public class ConfigBaseQuery {

    @NotNull(message = "所属模块不能为空")
    @Schema(description = "所属模块")
    private Long moduleId;

    @NotBlank(message = "编码不能为空")
    @Schema(description = "编码")
    private String code;

    @NotBlank(message = "名称不能为空")
    @Schema(description = "名称")
    private String name;

    @Schema(description = "排序")
    private Integer sort;

    @NotBlank(message = "类型不能为空")
    @Schema(description = "类型(待办、已办、待阅、已阅、督办、已发)")
    private String type;

    @NotBlank(message = "接口模式不能为空")
    @Schema(description = "接口模式（url、service）")
    private String interfaceType;

    @NotBlank(message = "接口不能为空")
    @Schema(description = "数量接口")
    private String countInterface;

    @NotBlank(message = "接口不能为空")
    @Schema(description = "列表接口")
    private String listInterface;

    @Schema(description = "打开方式(组件：component 路由：router  地址：url)")
    private String openType;

    @Schema(description = "组件/路由 地址(带参数模版)")
    private String openPage;

    @Schema(description = "是否启用")
    @TableField("is_enable")
    private Integer isEnable;

    @Schema(description = "是否待处理接口")
    @TableField("is_pending_process")
    private Integer isPendingProcess;

    @Schema(description = "图标")
    @TableField("icon")
    private String icon;
}
